<template>
  <div>
    <router-view></router-view>
  </div>
</template>

<script>
// vuex
import { createNamespacedHelpers } from 'vuex'
const { mapActions } = createNamespacedHelpers('system')
export default {
  data() {
    return {}
  },
  computed: {
    userAuthority() {
      const a = this.$store.getters.userAuthority
      if (a === 'manageEnd') {
        this.getOrganList()
      }
      return a
    },
  },
  methods: {
    ...mapActions(['getSystemThemeList', 'getProductList', 'getFieldsList', 'getOrganList', 'getSystemRoleList']),

    _isMobile() {
      let flag = navigator.userAgent.match(
        /(phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone)/i,
      )
      return flag
    },
  },
  mounted() {
    /* this.getSystemThemeList()
    this.getProductList()
    this.getFieldsList()
    this.getSystemRoleList()
    this.userAuthority // 不可删除 */
  },
}
</script>

<style lang="less" scoped></style>
